﻿#ifndef FROMMAIN_H
#define FROMMAIN_H

#include <QMainWindow>
#include <QDragEnterEvent>
QT_BEGIN_NAMESPACE
namespace Ui {
class FromMain;
}
QT_END_NAMESPACE

class FromMain : public QMainWindow
{
    Q_OBJECT

public:
    FromMain(QWidget *parent = nullptr);
    ~FromMain();

private slots:
    void showImg(const QString &in_filePath);
    void selectFormt(const QString &in_filePath,int width,int height,const QString &format);
    void on_btnLoad_clicked();
    void on_btnSplit_clicked();
    void on_btnSplit_2_clicked();
    void on_btnYuvToRgb_clicked();
    void on_btnRgbToYuv_clicked();
    void on_btnYuvSplit_clicked();
    void on_btnRgbF_clicked();
    void on_btnYuvF_clicked();
    void on_btnSelectFile_clicked();
    void on_btnReload_clicked();
    void on_btnYuvGray_clicked();

    void on_btnYuvYHalf_clicked();

    void on_btnPnsr_clicked();

protected:
    void dragEnterEvent(QDragEnterEvent *event) override;
    void dropEvent(QDropEvent *event) override;
private:
    Ui::FromMain *ui;
    QImage m_img;
    QString m_filePath;
};
#endif // FROMMAIN_H
